<%= form_for @user_profile , :html => { :multipart => true }  do |f| %>
<% if @user_profile.errors.any? %>
<div id="error_explanation">
	<h2><%= pluralize(@user_profile.errors.count, "error") %> prohibited this user_profile from being saved:</h2>

	<ul>
		<% @user_profile.errors.full_messages.each do |msg| %>
		<li>
			<%= msg %>
		</li>
		<% end %>
	</ul>
</div>
<% end %>

<div class="form_rowProfile">
	<strong class="contact"><%= f.label t("firstname") %></strong>
	<%= f.text_field :firstname , :html => {:class => "contact_input"}%>
	<span id="spanFN" style="color: red;"></span>
</div>
<div class="form_rowProfile">
	<strong class="contact"><%= f.label t("lastname")  %></strong>
	<%= f.text_field :lastname ,:html => {:class => "contact_input"} %>
	<span id="spanLN" style="color: red;"></span>
</div>
<div class="form_rowProfile">
	<strong class="contact"><%= f.label t("mssv") %></strong>
	<%= f.text_field :mssv ,:html => {:class => "contact_input"}%>
	<span id="spanMSSV" style="color: red;"></span>
</div>
<div class="form_rowProfile">
	<strong class="contact"><%= f.label t("address") %></strong>
	<%= f.text_field :address ,:html => {:class => "contact_input"}%>
</div>
<div class="form_rowProfile">
	<strong class="contact"><%= f.label t("birthday") %></strong>
	<%= f.date_select :birth_of_day, :order => [:day,:month,:year] ,:html => {:class => "contact_input"}%>
</div>
<div class="form_rowProfile">
	<strong class="contact"><%= f.label t("email") %></strong>
	<%= f.email_field :email  ,:html => {:class => "contact_input"}%>
	<span id="spanEmail" style="color: red;"></span>
</div>
<div class="form_rowProfile">
	<strong class="contact"><%= f.label t("password") %></strong>
	<%= f.password_field :password ,:html => {:class => "contact_input"}%>
	<span id="spanPass2" style="color: red;"></span>
	<span id="spanPass1" style="color: red;"><%= @notice %></span>
	
</div>

<div class="form_row">
	<strong class="contact"><%= f.label t("avatar") %></strong>
		<%= f.file_field :avatar %>
</div>

<div class="form_row">
	<input type="submit" class="register" value="<%= t :update %>" />

</div>
<br />
<% end %>
